package com.cyy.system.controller;

import cn.dev33.satoken.annotation.SaCheckLogin;
import com.cyy.common.domain.Response;
import com.cyy.common.service.CommentService;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 * 评论表 前端控制器
 * </p>
 *
 * @author 曹云友
 * @since 2024-04-01
 */
@Tag(name = "评论")
@Slf4j
@RestController
@RequestMapping("/system/comment")
@RequiredArgsConstructor
@SaCheckLogin
public class CommentController {

    private final CommentService commentService;

    @Operation(summary = "删除评论")
    @DeleteMapping("/{ids}")
    public Response deleteComment(@PathVariable(name = "ids") String ids) {
        commentService.deleteComment(ids);
        return Response.success();
    }


}
